package ulmermark.demo.concurrency.core;

import ulmermark.demo.concurrency.core.inbox.Inbox;

public abstract class Target<T extends Object> {

	private final Inbox inbox;
	
	public Target(final Inbox inbox){
		this.inbox = inbox;
	}
	public abstract void received(T message);
	
	public void deliver(T payload){
		this.inbox.deliver( this, payload);
	}
	
}
